<?php  echo $_SERVER['SCRIPT_NAME']."<BR>"; ?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="../include/main.css" rel="stylesheet" type="text/css">
</head>
<body>
<table width="100%"  border="0" cellspacing="6" cellpadding="6">
  <tr>
    <td><div align="right" class="txt24bb_white">NULL and is_null() </div></td>
  </tr>
</table>
<br>
<br>
<table width="500" border="0" align="center" cellpadding="1" cellspacing="1" class="tbl_border">
  <tr>
    <td><table width="100%"  border="0" cellpadding="0" cellspacing="0" class="tbl_gray_wborder">
        <tr>
          <td class="txt14b_black">            <p><span class="txt14_red">note that a FALSE value doesn't display a value!!</span><span class="txt16b_blue"><br>
              <br>
              Let's set a few variables to NULL:</span><br>
              (see source code, setting $foo, $foo2, $foo3) <br>
              <?php
				$foo = NULL;
				$foo2 = NULL;
				$foo3 = NULL;
				$foo4 = "Hello!";
			  ?>
              <br>
              <span class="txt16b_blue">Test for NULL ($foo4 is not NULL)</span><br>
          <?php
				if (is_null($foo)) echo "\$foo is NULL!!<BR>";
				if (is_null($foo2)) echo "\$foo2 is NULL!!<BR>";
				echo "The value of isset(\$foo3) is:",isset($foo3), "<BR>";;
				echo "The value of isset(\$foo4) is:",isset($foo4), "<BR><BR>";
				echo "The value of is_null(\$foo3) is:",is_null($foo3), "<BR>";;
				echo "The value of is_null(\$foo4) is:",is_null($foo4), "<BR><BR>";
				if (is_null($foo4)) echo "\$foo4 is NULL!!<BR>";
			?>
          <br> 
          <span class="txt16b_blue">Re-assign some values: </span><br>
          (see source, changing $foo2, $foo3, $foo4)<br>
          <?php 
				$foo2 = "Test!";
				$foo3 = NULL;
				$foo4 = "NULL!";
				
		  ?>
          <br>
          <span class="txt16b_blue">Let's see the results:</span><br>
          (see source code)<br>
          <?php
				if (is_null($foo)) echo "\$foo is NULL!!<BR>";
				if (is_null($foo2)) echo "\$foo2 is NULL!!<BR>";
				echo "The value of isset(\$foo3) is:",isset($foo3), "<BR>";;
				echo "The value of isset(\$foo4) is:",isset($foo4), "<BR><BR>";
				echo "The value of is_null(\$foo3) is:",is_null($foo3), "<BR>";;
				echo "The value of is_null(\$foo4) is:",is_null($foo4), "<BR><BR>";
				if (is_null($foo4)) echo "\$foo4 is NULL!!<BR>";
				
				// unset($foo3);
			?>
          <br>
</p>          </td>
        </tr>
    </table></td>
  </tr>
</table>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
</body>
</html>